-- GENERATED SPELL FOR [Iron Rune Sage] --


function spell0_23674(pUnit, Event) --@Cone of Cold,Self--
pUnit:FullCastSpellOnTarget(20828,pUnit)
pUnit:RegisterEvent('Sorts_23674', 8294, 1)
end

function spell1_23674(pUnit, Event) --@Fireball,n/a--
pUnit:FullCastSpellOnTarget(20823,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_23674', 3000, 1)
end

function Sorts_23674(pUnit, Event)
local choix_sorts_23674 = math.random(0, 1)
if choix_sorts_23674 == 0 then
pUnit:RegisterEvent('spell0_23674', 1, 1)
end
if choix_sorts_23674 == 1 then
pUnit:RegisterEvent('spell1_23674', 1, 1)
end
end

function mob23674_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_23674', math.random(1500, 3000), 1)
end

function mob23674_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob23674_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob23674_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(23674, 1, 'mob23674_Action')
RegisterUnitEvent(23674, 2, 'mob23674_Leave')
RegisterUnitEvent(23674, 3, 'mob23674_Kill')
RegisterUnitEvent(23674, 4, 'mob23674_Die')
